<template>
  <div style="box">
    <el-row :gutter="18">
      <el-col :span="24">
        <div class="grid-content bg-purple">
          <el-menu :default-active="activeIndex" class="el-menu-demo" mode="horizontal" @select="handleSelect" router>
            <el-menu-item index="/home">Home</el-menu-item>
            <!-- <el-menu-item index="4" disabled><a href="https://www.ele.me" target="_blank">友情链接</a></el-menu-item> -->
            <el-menu-item index="/write"><a href="#/write">写</a></el-menu-item>
            <el-menu-item index=""><router-link to="/login">登录</router-link></el-menu-item>
            <el-menu-item index=""><router-link to="/conponentcol">组件收藏界面</router-link></el-menu-item>
          </el-menu>
        </div>
      </el-col>
    </el-row>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        activeIndex: '1',
        activeIndex2: '1'
      };
    },
    methods: {
      handleSelect(key, keyPath) {
        console.log(key, keyPath);
      }
    }
  }
</script>


<style>
  .box{
    width: 98%;
    margin: 0 0 0 10px;
  }
  .itemBackground img{
    width: auto;
    height: 200px;
  }
.el-row {
    margin-bottom: 20px;
  }
  .el-col {
    border-radius: 4px;
  }
  .bg-purple-dark {
    background: #99a9bf;
  }
  .bg-purple {
    background: #d3dce6;
  }
  .bg-purple-light {
    background: #e5e9f2;
  }
  .grid-content {
    border-radius: 4px;
    min-height: 36px;
  }
  .row-bg {
    padding: 10px 0;
    background-color: #f9fafc;
  }
</style>
